﻿using System;
using System.Collections.Generic;
using System.Xml.Serialization;

namespace LdtJudge.DataEngine.Model.XMLConfigModel.LawElementModel
{
    /// <summary>
    /// 法规信息
    /// </summary>
    [Serializable]
    [XmlRootAttribute("详情", IsNullable = false)]
    public class LawModel
    {
        /// <summary>
        /// 法律ID
        /// </summary>
        [XmlAttribute("引用法规ID")]
        public string LawID;

        /// <summary>
        /// 法律名称
        /// </summary>
        [XmlAttribute("引用法规名称")]
        public string LawName;

        /// <summary>
        /// 法律排序
        /// </summary>
        [XmlAttribute("法规类型排序")]
        public string LawOreder;
        /// <summary>
        /// 法律标记
        /// </summary>
        [XmlAttribute("法律标记")]
        public string LawSging;

        /// <summary>
        /// 法律类型
        /// </summary>
        [XmlAttribute("法规类型")]
        public string LawType;

        /// <summary>
        /// 发布时间
        /// </summary>
        [XmlAttribute("发布日期")]
        public string LawData;


        [XmlElementAttribute("引用条详情", IsNullable = false)]
        public List<LawProv> lawProvList = new List<LawProv>();
    }

    /// <summary>
    /// 法条信息
    /// </summary>
    [Serializable]
    [XmlRootAttribute("引用条详情", IsNullable = false)]
    public class LawProv
    {
        /// <summary>
        ///法条ID
        /// </summary>
        [XmlAttribute("引用条ID")]
        public string ProvID;
        /// <summary>
        /// 法条名称
        /// </summary>
        [XmlAttribute("引用条名称")]
        public string ProvName;

        /// <summary>
        /// 法规ID
        /// </summary>
        [XmlAttribute("引用法规ID")]
        public string LawID;

        /// <summary>
        /// 是否为定罪
        /// </summary>
        public string IsConviction;

        [XmlElementAttribute("引用款详情", IsNullable = false)]
        public List<LawClause> lawClauseList = new List<LawClause>();
    }

    /// <summary>
    /// 法款信息
    /// </summary>
    [Serializable]
    [XmlRootAttribute("引用款详情", IsNullable = false)]
    public class LawClause
    {
        /// <summary>
        /// 法款ID
        /// </summary>
        [XmlAttribute("引用款ID")]
        public string ClauseID;
        /// <summary>
        ///法款名称
        /// </summary>
        [XmlAttribute("引用款名称")]
        public string ClauseName;

        [XmlElementAttribute("引用项详情", IsNullable = false)]
        public List<LawItem> lawItemList = new List<LawItem>();
    }

    /// <summary>
    /// 法项信息
    /// </summary>
    [Serializable]
    [XmlRootAttribute("引用项详情", IsNullable = false)]
    public class LawItem
    {
        /// <summary>
        /// 法项ID
        /// </summary>
        [XmlAttribute("引用项ID")]
        public string ItemID;
        /// <summary>
        /// 法项名称
        /// </summary>
        [XmlAttribute("引用项名称")]
        public string ItemName;
    }
    [Serializable]
    [XmlRootAttribute("引用法规", IsNullable = false)]
    public class LawModelList
    {

        [XmlElementAttribute("详情", IsNullable = false)]
        public List<LawModel> lawModels = new List<LawModel>();
    }
}
